/*  1:   */ package org.jetbrains.jps.service.impl;
/*  2:   */ 
/*  3:   */

import org.jetbrains.jps.service.SharedThreadPool;

import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
import java.util.concurrent.Future;

/*  4:   */
/*  5:   */
/*  6:   */
/*  7:   */ 
/*  8:   */ public class SharedThreadPoolImpl
/*  9:   */   extends SharedThreadPool
/* 10:   */ {
/* 11:28 */   private final ExecutorService a = Executors.newCachedThreadPool();
/* 12:   */   
/* 13:   */   public void execute(Runnable paramRunnable)
/* 14:   */   {
/* 15:32 */     executeOnPooledThread(paramRunnable);
/* 16:   */   }
/* 17:   */   
/* 18:   */   public Future<?> executeOnPooledThread(final Runnable paramRunnable)
/* 19:   */   {
/* 20:37 */     this.a.submit(new Runnable()
/* 21:   */     {
/* 22:   */       public void run()
/* 23:   */       {
/* 24:   */         try
/* 25:   */         {
/* 26:41 */           paramRunnable.run();
/* 27:   */         }
/* 28:   */         finally
/* 29:   */         {
/* 30:44 */           Thread.interrupted();
/* 31:   */         }
/* 32:   */       }
/* 33:   */     });
/* 34:   */   }
/* 35:   */ }



/* Location:           E:\idea\

 * Qualified Name:     org.jetbrains.jps.service.impl.SharedThreadPoolImpl

 * JD-Core Version:    0.7.0.1

 */